<?php
/*
# ------------------------------------------------------------------------
# JA Job Board Package
# ------------------------------------------------------------------------
# Copyright (C) 2004-2010 JoomlArt.com. All Rights Reserved.
# @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
# Author: JoomlArt.com
# Websites: http://www.joomlart.com - http://www.joomlancers.com.
# ------------------------------------------------------------------------
*/
  defined('_JEXEC') or die('Retricted Access');
  
  JHTML::_('behavior.tooltip');
?>

<form name="adminForm" action="index.php" method="post">
    <div style="width:100%;">
		<table width="100%">
        <tr>
      
        <td valign="top">
        <table>
			<tr>
				<td align="left" width="100%">
					<?php echo JText::_( 'Filter' ); ?>:
					<input type="text" name="user_search" id="user_search" value="<?php echo $this->search;?>" class="text_area" onchange="document.adminForm.submit();" />					
                    <button onclick="this.form.submit();"><?php echo JText::_( 'Go' ); ?></button>
					<button onclick="document.getElementById('user_search').value='';this.form.submit();"><?php echo JText::_( 'Reset' ); ?></button>
				</td>
				
			</tr>
		</table>
       
		<table class="adminlist">
        	<thead>
				<tr>
					<th width="20">
						<?php echo JText::_( 'NUM' ); ?>
					</th>
					<th>            		
<!--            			<?php echo JHTML::_('grid.sort',   JText::_('Name'), 'name',@$this->lists['order_Dir'], @$this->lists['order']); ?>-->
						<?php echo JText::_('Name'); ?>
            		</th>
					<th>            		
            			<!--<?php echo JHTML::_('grid.sort',   JText::_('Username'), 'username',@$this->lists['order_Dir'], @$this->lists['order']); ?>-->
            			<?php echo JText::_('Username'); ?>
            		</th> 
            		<th>            		
            			<!--<?php echo JHTML::_('grid.sort',   JText::_('Usertype'), 'user_type',@$this->lists['order_Dir'], @$this->lists['order']); ?>-->
            			<?php echo JText::_('Usertype'); ?>
            		</th> 
					<th>            		
            			<!--<?php echo JHTML::_('grid.sort',   JText::_('E-Mail'), 'email',@$this->lists['order_Dir'], @$this->lists['order']); ?>-->
            			<?php echo JText::_('E-mail'); ?>
            		</th> 
            		<th>            		
            			<!--<?php echo JHTML::_('grid.sort',   JText::_('User ID'), 'id',@$this->lists['order_Dir'], @$this->lists['order']); ?>-->
            			<?php echo JText::_('User ID'); ?>
            		</th> 
            	</tr>
			</thead>
			<tbody>
        	<?php
        	$items = $this->items;
        	for($i = 0, $orderNo=0, $n = count($items); $i < $n; $i++, $orderNo++){
        		$item = $items[$i]
        	?>
        	<tr>
        		<td>
        			<?php echo $i + 1; ?>
        		</td>
        		<td>
        			<a style="cursor: pointer;" href="#" onclick="window.parent.assign_user('<?php echo $item->id; ?>');"><?php echo $item->name; ?> </a>
        		</td>
        		<td>
        			<?php echo $item->username; ?>
        		</td>
        		<td>
        			<?php echo $item->user_type; ?>
        		</td>
        		<td>
        			<?php echo $item->email; ?>
        		</td>
        		<td>
        			<?php echo $item->id; ?>
        		</td>
        	</tr>	
        	<?php
        		
			}
        	?>
        	<tbody>
        	<tfoot>
				<tr>
					<td colspan="9">
						<?php //echo $this->pagination->getListFooter(); ?>
					</td>
				</tr>
			</tfoot>
		</table>
        </td>
        </tr>
        </table>
	</div>
	<input type="hidden" name="option" value="<?php echo 'com_jajobboard'; ?>" />
	<input type="hidden" name="view" value="jatransactions" />
	<input type="hidden" name="layout" value="element_user" />
	<input name="tmpl" value="component" type="hidden" />
    <input type="hidden" name="task" value="" />
	<!--<input type="hidden" name="table_name" value="<?php echo $this->table_name;?>" />-->
	<?php echo JHTML::_( 'form.token' ); ?>	
 </form>
